package com.nix.web.controller;

import com.nix.Exception.PermissionException;
import org.apache.log4j.Logger;
import org.springframework.web.bind.annotation.ExceptionHandler;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * Create by zhangpe0312@qq.com on 2018/3/18.
 */
public class BaseController {
    //日志记录
    private static Logger logger = Logger.getLogger(BaseController.class);

    @ExceptionHandler(PermissionException.class)
    @ResponseBody
    public  String permissionException(){
        return "权限不足";
    }

}
